package com.yjd.comm.easycard.enums;


/**
 * @author 易借卡各项异常
 *
 */
public enum EasycardExceptionEnum {
 
	SyncCreditErrorException("SyncCreditErrorException","同步用户信用额度异常"),
	TakeSnapshotErrorException("TakeCreditSnapshotErrorException","获取用户快照信息异常");
	
	private String exception;
	private String description;

	private EasycardExceptionEnum(String exception, String description) {
		this.exception = exception;
		this.description = description;
	}

	public String getException() {
		return exception;
	}

	public String getDescription() {
		return description;
	}

	public static EasycardExceptionEnum get(String value) {
		EasycardExceptionEnum[] enums = EasycardExceptionEnum.values();
		for (EasycardExceptionEnum enum1 : enums) {
			if (enum1.getException().equals(value)) {
				return enum1;
			}
		}
		return null;
	}

	public static String getDesc(String value) {
		EasycardExceptionEnum enum1 = EasycardExceptionEnum.get(value);
		return enum1 != null ? enum1.getDescription() : null;
	}
	
}